<!-- post list -->
{{ range $index, $element := $.Paginator.Pages }}
<div class="post-preview" >
    <div class="post-thumbnail">
        <div class="post-thumb-inner" style="
            background-image: url({{ .Permalink }}{{.Params.image}});">
            <a href="{{ .Permalink }}">
                <div class="overlay"></div>
            </a>
        </div>
    </div>
    <div class="post-text">
        <p class="post-meta">
            {{ if .Params.metadata }}
                {{ range $index, $element := .Params.metadata }}
                    {{ if .link }}
                        <a href="{{ .link }}">{{ .text }}</a>
                    {{ else }}
                        {{ .text }}
                    {{ end }}
                {{ end }}
            {{ else }}
                {{ .Date.Format "2006.01.02" }}
            {{ end }}
        </p>

        <a class="post-link" href="{{ .Permalink }}">
            <h2 class="post-title">
                {{ .Title }}
            </h2>
        </a>
        <div class="post-content-preview">
            {{ with .Description }}
            {{ . }}
            {{ else }}
            {{ .Summary}}
            {{ end }}
            {{ if .Truncated }}
            <a href="{{ .Permalink }}">阅读全文…</a>
            {{ end }}
        </div>
    </div>
</div>
<!--     <p class="post-meta" style="float: right; width: 60%;">
    {{ if .Params.metadata }}
        {{ range $index, $element := .Params.metadata }}
            {{ if .link }}
                <a href="{{ .link }}">{{ .text }}</a>
            {{ else }}
                {{ .text }}
            {{ end }}
        {{ end }}
    {{ else }}
        Posted by {{ with .Params.author }}{{ . }}{{ else }}{{ .Site.Title }}{{ end }}  {{ .Date.Format "Monday, January 2, 2006" }}

        {{ if (and (not .Lastmod.IsZero) (not (eq (dateFormat "2006-01-02" .Lastmod) (dateFormat "2006-01-02" .Date)))) }}
            <br>Last Modified on {{ dateFormat "Monday, January 2, 2006" .Params.LastMod }} 
        {{ end }}
    {{ end }}
    </p> -->
<hr>
{{ end }}